<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        var tom={name:"tom",age:18};

        //枚举，将对象中的key逐个取出（无序）
        for(var key in tom){
            console.log(key+"->"+tom[key]);
        }

        for(var key in window){
            console.log(key+"->"+window[key]);
        }

        delete tom.name;  //删除对象中名为name的属性

        console.log("name" in tom);  //name属性是否在对象中

        console.log(tom instanceof Object);
        console.log(Object instanceof Function);
        console.log(Function instanceof Function);
    </script>
</body>
</html>